﻿using Cl.Utils.Primitives.Const.UserLogin;
using Cl.WebApi.Authorization.CustomerAttributes;
using Cl.WebApi.Controllers;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;

namespace Cl.WebApi.Areas.Other.Test
{

    /// <summary>
    /// 测试混合权限
    /// </summary>
    [Route("api/[controller]")]
    [ApiController]
    public class TestMingleController : ClientMingleController
    {

        /// <summary>
        /// 管理员审核
        /// </summary>
        /// <returns></returns>
        [HttpGet]
        [AuthorizeAction(ClientTypeConst.Admin)]
        public string AdminAudit()
        {
            return "1";
        }


        /// <summary>
        /// 客户审核
        /// </summary>
        /// <returns></returns>
        [HttpGet]
        [AuthorizeAction(ClientTypeConst.Customer)]
        public string CustomerAudit()
        {
            return "2";
        }
    }
}
